package dao;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import entity.Emp;

public class EmpDao implements Serializable {

	private static final long serialVersionUID = 1L;
	
	public List<Emp> findAll(){
		//模拟查询所有的员工
		List<Emp> list = new ArrayList<Emp>();

		Emp e1 = new Emp(1,"唐僧","取经",8000.0);
		list.add(e1);
		Emp e2 = new Emp(2,"悟空","取经",6000.0);
		list.add(e2);
		Emp e3 = new Emp(3,"八戒","取经",5000.0);
		list.add(e3);
		Emp e4 = new Emp(4,"沙僧","取经",4000.0);
		list.add(e4);
		
		return list;
		
	}
	
	public void save(Emp e){
		
		System.out.println("增加员工:"+e.getName());
		
	
	}

}
